#define _CRT_SECURE_NO_WARNINGS
#include<stdio.h>
int search(int arr[], int n)
{
	int x = 0;
	for (int i = 0; i <= n; i++)
	{
		x ^= i;
	}
	for (int i = 0; i < n; i++)
	{
		x ^= arr[i];
	}
	return x;

}
int main()
{
	int arr[] = { 6,3,4,2,0,1 };
	int n = sizeof(arr) / sizeof(arr[0]);
	int x=search(arr, n);
	printf("%d", x);
	return 0;
}